﻿using Basic.FormRemoteModel.PageLayout.Search;

namespace Basic.FormRemoteModel.PageBody.Model
{
    public class PageControlDto
    {
        public long Id
        {
            get;
            set;
        }
        public long ControlId { get; set; }

        public string Code
        {
            get;
            set;
        }
        public string Name { get; set; }

        /// <summary>
        /// 宽度比例
        /// </summary>
        public byte WidthRatio { get; set; }
        /// <summary>
        /// 高度占格数（1格=14px）
        /// </summary>
        public byte HeightGrid { get; set; }

        /// <summary>
        /// 页面控件类型
        /// </summary>
        public PageControlType ControlType { get; set; }

        /// <summary>
        /// 控件路径
        /// </summary>
        public string ControlPath { get; set; }

        /// <summary>
        /// 提示说明
        /// </summary>
        public string Show { get; set; }

        public string Classify { get; set; }

        /// <summary>
        /// 统计配置
        /// </summary>
        public StatisticsConfig Statistics
        {
            get;
            set;
        }

        /// <summary>
        /// 图表配置
        /// </summary>
        public ChartConfig Chart { get; set; }

        /// <summary>
        /// 统计表
        /// </summary>
        public CensusTableConfig CensusTable { get; set; }

        /// <summary>
        /// 明细表
        /// </summary>
        public TableConfig Table { get; set; }

        /// <summary>
        /// 控件配置
        /// </summary>
        public Dictionary<string, object> ControlSet { get; set; }

        /// <summary>
        /// 布局配置
        /// </summary>
        public Dictionary<string, object> Layout { get; set; }
        /// <summary>
        /// 搜索控件配置
        /// </summary>
        public SearchControl Search { get; set; }

        /// <summary>
        /// 下级控件
        /// </summary>
        public PageControlDto[] Children { get; set; }
    }
}
